﻿<common:QuibblerWindow
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:controls="clr-namespace:Indigo.Quibbler.Controls"
    xmlns:contentListControl="clr-namespace:Indigo.Quibbler.Controls;assembly=Indigo.Quibbler.Controls"
    xmlns:Microsoft_Windows_Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Luna"
    xmlns:data="clr-namespace:Indigo.Quibbler.Data"
    xmlns:local="clr-namespace:Indigo.Quibbler"
	xmlns:common="clr-namespace:Indigo.Quibbler.Common" 
    xmlns:sys="clr-namespace:System;assembly=mscorlib"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" x:Class="Indigo.Quibbler.EditionWindow"
    Title="Quibbler"    
	WindowStartupLocation="CenterScreen"
	Style="{StaticResource QuibblerWindowStyle}"
    x:Name="window"
	Width="Auto" Height="Auto" MinWidth="1000" MinHeight="600"
	WindowState="Maximized" 
	Foreground="#FFF2F2F2" Icon="/Images/Quibbler.ico"  mc:Ignorable="d" Background="#FFEAEAEA" FontFamily="Georgia" >
    <Window.Resources>

        <LinearGradientBrush x:Key="SeperaterGradient" EndPoint="1,0.5" StartPoint="0,0.5">
            <GradientStop Color="#FFEAEAEA" Offset="0"/>
            <GradientStop Color="#FF656565" Offset="1"/>
            <GradientStop Color="#FFEAEAEA" Offset="0.5"/>
        </LinearGradientBrush>

        <local:NewsFolderItemsConverter x:Key="NewsFolderItemsConverter"/>
        <local:MultiplierConverter x:Key="MultiplierConverter"/>

        <DataTemplate x:Key="NewsFolderOverviewDataTemplate" DataType="{x:Type data:NewsSection}">
            <controls:SectionControlOverview Category="{Binding Category}" IsUpdated="{Binding IsUpdated, Mode=TwoWay, UpdateSourceTrigger=Default}"/>
        </DataTemplate>

        <DataTemplate x:Key="NewsFolderDataTemplate"
					  DataType="{x:Type data:NewsSection}">
            <controls:SectionControl x:Name="ElementVisual" Category="{Binding Category}" ItemSource="{Binding Path=NewsArticles, Converter={StaticResource NewsFolderItemsConverter}}" Mode="Details" Cursor="Hand" IsUpdated="{Binding IsUpdated, Mode=TwoWay, UpdateSourceTrigger=Default}">
            </controls:SectionControl>
        </DataTemplate>

        <DataTemplate x:Key="ArticleDataTemplate"
					  DataType="{x:Type data:NewsArticle}">
            <controls:ArticleControl x:Name="ElementVisual" Headline="{Binding Headline}" SubHeadline="{Binding SubHeadline}" PubDate="{Binding PubDate}" ImageUrl="{Binding ImageUrl}" SyncTime="{Binding SyncTime}" />
        </DataTemplate>

        <DataTemplate x:Key="VideoDataTemplate"
					  DataType="{x:Type data:NewsArticle}">
            <controls:VideoArticleControl Headline="{Binding Headline}" ImageUrl="{Binding ImageUrl}" VideoUrl="{Binding VideoUrl}" SyncTime="{Binding SyncTime}" />
        </DataTemplate>

        <DataTemplate x:Key="templateMasterItem" DataType="{x:Type sys:String}">
            <Border Margin="5,5,2,5" Height="30">
                <Grid>
                    <Image Source="pack://application:,,/Quibbler - Universal News Reader;component/Images/accordion-back.png" Stretch="Fill"/>
                    <Label Content="{Binding}" FontFamily="Georgia" Foreground="White" FontSize="13" Margin="45,5,0,0" Background="#00DEDEDE"/>
                </Grid>
            </Border>
        </DataTemplate>



        <DataTemplate x:Key="templateDetailsItem" DataType="{x:Type sys:String}">
            <Border BorderBrush="#FF515151" BorderThickness="0,1,0,0" Padding="3" Margin="5" Height="40">
                <TextBlock Text="{Binding Headline}" Foreground="#FF345B6D" Background="{x:Null}" TextTrimming="CharacterEllipsis" TextWrapping="Wrap"/>
            </Border>
        </DataTemplate>

        <DataTemplate x:Key="templateHeader" DataType="{x:Type sys:String}">
            <Border Margin="2">
                <Grid>
                    <Image Source="images/accordion-header-back.png" Stretch="None"/>
                    <Label Content="{Binding}" FontFamily="Georgia" Foreground="#FF345B6D" FontSize="16" Margin="30,0,0,0" FontWeight="Normal" Background="{x:Null}"/>
                </Grid>
            </Border>
        </DataTemplate>

        <DataTemplate x:Key="templateLoading">
            <Border Margin="5,5,5,250" CornerRadius="5" Background="#FF494949" Width="200" BorderBrush="#FFD0D0D0" BorderThickness="1" Opacity="0.5" >
                <Label Content="Loading..." Margin="5,2" Foreground="#FFB9B9B9" FontSize="12" HorizontalAlignment="Center"/>
            </Border>
        </DataTemplate>

        <Storyboard x:Key="sbShowSmallHeading">
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="label" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.2000000" Value="0"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="0"/>
            </DoubleAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="label" Storyboard.TargetProperty="(UIElement.Visibility)">
                <DiscreteObjectKeyFrame KeyTime="00:00:00.2000000" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:00.3000000" Value="{x:Static Visibility.Collapsed}"/>
            </ObjectAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="lblTimesTitleSmall" Storyboard.TargetProperty="(UIElement.Visibility)">
                <DiscreteObjectKeyFrame KeyTime="00:00:00.1000000" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:00.3000000" Value="{x:Static Visibility.Visible}"/>
            </ObjectAnimationUsingKeyFrames>
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="lblTimesTitleSmall" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00.1000000" Value="0"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="1"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="sbShowLargeHeading">
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="label" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="0"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.1000000" Value="0"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="1"/>
            </DoubleAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="label" Storyboard.TargetProperty="(UIElement.Visibility)">
                <DiscreteObjectKeyFrame KeyTime="00:00:00" Value="{x:Static Visibility.Collapsed}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:00.1000000" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:00.3000000" Value="{x:Static Visibility.Visible}"/>
            </ObjectAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="lblTimesTitleSmall" Storyboard.TargetProperty="(UIElement.Visibility)">
                <DiscreteObjectKeyFrame KeyTime="00:00:00" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:00.2000000" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:00.3000000" Value="{x:Static Visibility.Collapsed}"/>
            </ObjectAnimationUsingKeyFrames>
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="lblTimesTitleSmall" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.2000000" Value="0"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="0"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="sbHideToolbarControl">
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="toolbarControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="0"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="100"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="sbShowToolbarControl">
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="toolbarControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="100"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="0"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="sbLoadingText" RepeatBehavior="10">
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="border" Storyboard.TargetProperty="(Border.BorderBrush).(GradientBrush.GradientStops)[1].(GradientStop.Offset)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.01"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.5000000" Value="0.99"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="sbMessageFlash">

            <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="message" Storyboard.TargetProperty="(UIElement.Visibility)">
                <DiscreteObjectKeyFrame KeyTime="00:00:00" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:00.5000000" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:02.5" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="00:00:03" Value="{x:Static Visibility.Collapsed}"/>
            </ObjectAnimationUsingKeyFrames>
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="message" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="0"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.5000000" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:02.5" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:03" Value="0"/>
            </DoubleAnimationUsingKeyFrames>
            <ColorAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="message" Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)">
                <SplineColorKeyFrame KeyTime="00:00:00" Value="#B2000000"/>
                <SplineColorKeyFrame KeyTime="00:00:03" Value="#B2000000"/>
            </ColorAnimationUsingKeyFrames>

        </Storyboard>
    </Window.Resources>
    <Grid Background="#FFEAEAEA">
        <Grid x:Name="gridLayout">
            <Grid.RowDefinitions>
                <RowDefinition Height="135" />
                <RowDefinition Height="Auto"/>
                <RowDefinition Height="*"/>
                <RowDefinition Height="Auto" />
            </Grid.RowDefinitions>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="*"/>
                <ColumnDefinition Width="320"/>
            </Grid.ColumnDefinitions>
            <Label x:Name="lblTimesTitleSmall" Grid.Column="1" FontFamily="Georgia" FontSize="20" FontWeight="Bold" Foreground="Black" Content="Universal News Reader" Padding="0" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0,0,20,0" Opacity="1" Cursor="Hand" ToolTip="Click here to go back to sections view"/>
            <controls:SettingsToolbar Grid.Column="1" x:Name="settingsToolbar" VerticalAlignment="Bottom" HorizontalAlignment="Left" Margin="0,0,20,25"/>
            <Grid Grid.Row="0" Grid.ColumnSpan="1">
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
                
                <Label x:Name="label" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="101,25,100,25" FontFamily="Georgia" FontSize="64" FontWeight="Bold" Foreground="Black" Content="Universal News Reader" Padding="0" Visibility="Visible" Opacity="1" ToolTip="Universal News Reader"/>
            </Grid>
            <Grid x:Name="gridContentListControl" Grid.Column="0" Grid.Row="2" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="*"/>
                </Grid.ColumnDefinitions>
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
                <contentListControl:ContentList x:Name="contentListControl"
                	Grid.Row="0"
                	Grid.Column="0"
                	ItemTemplate="{StaticResource NewsFolderDataTemplate}" ItemsSource="{Binding ListMainView, ElementName=window, Mode=Default}"
				    Width="{Binding ActualHeight, Converter={StaticResource MultiplierConverter}, ConverterParameter=1.5, ElementName=contentListControl, Mode=Default}"
                    HorizontalAlignment="Center" MaxWidth="{Binding ActualWidth, ElementName=gridContentListControl}" 
					ScrollUpImage="pack://application:,,/Quibbler - Universal News Reader;component/Images/ScrollUp.png" ScrollUpHoverImage="pack://application:,,/Quibbler - Universal News Reader;component/Images/ScrollUp.png"
					ScrollDownImage="pack://application:,,/Quibbler - Universal News Reader;component/Images/ScrollDown.png" ScrollDownHoverImage="pack://application:,,/Quibbler - Universal News Reader;component/Images/ScrollDown.png"
				        >
                    <contentListControl:ContentList.Settings>
                        <contentListControl:ElementFlowSettings
                			ElementWidth="370"
                			ElementHeight="280"
                			ItemGap="0.35"
                			PopoutDistance="2"
                			TiltAngle="60"
                			View="CoverFlow"
                			EntryPoint="0,1,2"
                			ExitPoint="0,1,2"
                			InitialSelection="CenterItem"
                			FrontItemGap="0.7"
					            >
                            <contentListControl:ElementFlowSettings.Camera>
                                <PerspectiveCamera FieldOfView="60"
                					Position="0,1,6"
                					LookDirection="0,-1.2,-6"
                					UpDirection="0,1.2,0" />
                            </contentListControl:ElementFlowSettings.Camera>
                        </contentListControl:ElementFlowSettings>
                    </contentListControl:ContentList.Settings>
                </contentListControl:ContentList>
            </Grid>
            <controls:PhotoGalleryControl x:Name="photoGalleryControl" Margin="20,10" RenderTransformOrigin="0.5,0.5" Grid.Row="2" Grid.Column="0" Visibility="Collapsed">
                <!--<controls:PhotoGalleryControl.Background>
                    <ImageBrush ImageSource="pack://application:,,/Quibbler - Universal News Reader;component/Images/backgroundGlow.png"/>
                </controls:PhotoGalleryControl.Background>-->
                <controls:PhotoGalleryControl.RenderTransform>
                    <TransformGroup>
                        <ScaleTransform/>
                        <SkewTransform/>
                        <RotateTransform/>
                        <TranslateTransform/>
                    </TransformGroup>
                </controls:PhotoGalleryControl.RenderTransform>
            </controls:PhotoGalleryControl>
            <controls:ArticleGalleryControl x:Name="articleGalleryControl" Margin="20,10" RenderTransformOrigin="0.5,0.5" Grid.Row="2" Grid.Column="0" Visibility="Collapsed">
                <!--<controls:ArticleGalleryControl.Background>
                    <ImageBrush ImageSource="pack://application:,,/Quibbler - Universal News Reader;component/Images/backgroundGlow.png"/>
                </controls:ArticleGalleryControl.Background>-->
                <controls:ArticleGalleryControl.RenderTransform>
                    <TransformGroup>
                        <ScaleTransform/>
                        <SkewTransform/>
                        <RotateTransform/>
                        <TranslateTransform/>
                    </TransformGroup>
                </controls:ArticleGalleryControl.RenderTransform>
            </controls:ArticleGalleryControl>
            <controls:SpiderControl x:Name="spiderControl" Margin="20,10" RenderTransformOrigin="0.5,0.5" Grid.Row="2" Grid.Column="0" Visibility="Collapsed">
                <!--<controls:SpiderControl.Background>
                    <ImageBrush ImageSource="pack://application:,,/Quibbler - Universal News Reader;component/Images/backgroundGlow.png"/>
                </controls:SpiderControl.Background>-->
                <controls:SpiderControl.RenderTransform>
                    <TransformGroup>
                        <ScaleTransform/>
                        <SkewTransform/>
                        <RotateTransform/>
                        <TranslateTransform/>
                    </TransformGroup>
                </controls:SpiderControl.RenderTransform>
            </controls:SpiderControl>
            <Grid Grid.Row="1" Grid.Column="1" Grid.RowSpan="2">
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
                <Grid Grid.Row="0">
                    <contentListControl:Accordion x:Name="accordionControl" AnimationDuration="00:00:00.1"
			            MasterItemsSource="{Binding Data, ElementName=window, Mode=Default}"
			            MasterItemTemplate="{StaticResource templateMasterItem}"
			            DetailsItemTemplate="{StaticResource templateDetailsItem}"
			            HeaderTemplate="{StaticResource templateHeader}"
			            LoadingMessageTemplate="{StaticResource templateLoading}"
			            Width="300" VerticalAlignment="Stretch"
			            MasterItemHeight="30" DetailsItemHeight="40" HeaderHeight="35"
			            HorizontalAlignment="Left" Margin="0,0,0,10" Background="Transparent"
                        Grid.Row="0"
			        />
                    <controls:AdsControl HorizontalAlignment="Left" x:Name="adsControlTop" Visibility="Collapsed" VerticalAlignment="Center" Height="250" Opacity="1" Cursor="Hand"/>
                </Grid>
                <controls:AdsControl HorizontalAlignment="Left" x:Name="adsControlBottom" Visibility="Visible" VerticalAlignment="Center" Height="250" Opacity="1" Grid.Row="1" Cursor="Hand"/>
            </Grid>
            <Border x:Name="lblSpiderMode" Background="#FF699FBB" BorderThickness="1" CornerRadius="6" Margin="10,0,20,0" Grid.Row="1" Grid.Column="0" Visibility="Collapsed">
                <Label  x:Name="lblSpiderModeText" Foreground="#FFFFFFFF" Background="{x:Null}" VerticalAlignment="Center" HorizontalAlignment="Left" FontSize="12"  FontFamily="Georgia" Content="SEARCH RESULTS"/>
            </Border>
            <controls:SubCategoryControl x:Name="subCategoryControl" Margin="20,0,10,0" RenderTransformOrigin="0.5,0.5" Grid.Row="1" Grid.Column="0" Height="0"/>
            <!--<contentListControl:ContentList x:Name="headerContentListControl"
            	ItemTemplate="{StaticResource NewsFolderOverviewDataTemplate}"
            	Height="131" Width="750" ClipToBounds="True"                                              
            	HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="10,0,0,0" ItemsSource="{Binding ListOverviewSections, ElementName=window, Mode=Default}">
                <contentListControl:ContentList.Settings>
                    <contentListControl:ElementFlowSettings
            			ElementWidth="113"
            			ElementHeight="68"
            			ItemGap="2.7"
            			PopoutDistance=".3"
            			TiltAngle="0"
            			View="Carousel"
            			EntryPoint="0,0,0"
                        ExitPoint="0,0,0"
            			InitialSelection="CenterItem"
            			FrontItemGap=".5"
						ShowScrollbar="False"
					            >
                        <contentListControl:ElementFlowSettings.Camera>
                            <PerspectiveCamera FieldOfView="45"
            					Position="0,1.8,19"
            					LookDirection="0, -1.8, -19"
            					UpDirection="0,1,0" />
                        </contentListControl:ElementFlowSettings.Camera>
                    </contentListControl:ElementFlowSettings>
                </contentListControl:ContentList.Settings>
            </contentListControl:ContentList>-->
            <contentListControl:ContentList x:Name="headerContentListControl"
            	ItemTemplate="{StaticResource NewsFolderOverviewDataTemplate}"
            	Height="131" ClipToBounds="True"                                              
            	HorizontalAlignment="Stretch" VerticalAlignment="Bottom" Padding="0,0,0,0" Margin="5,0,5,0" ItemsSource="{Binding ListOverviewSections, ElementName=window, Mode=Default}">
                <contentListControl:ContentList.Settings>
                    <contentListControl:ElementFlowSettings
            			ElementWidth="153"
            			ElementHeight="68"
            			ItemGap="0.15"
            			PopoutDistance=".4"
            			TiltAngle="0"
            			View="Tile"
            			EntryPoint="0,0,0"
                        ExitPoint="0,0,0"
            			InitialSelection="CenterItem"
            			FrontItemGap=".5"
						ShowScrollbar="False"
                        Rows="2"
                        Columns="6">
                        <contentListControl:ElementFlowSettings.Camera>
                            <PerspectiveCamera FieldOfView="45"
            					Position="0,0,19"
            					LookDirection="0, 0, -19"
            					UpDirection="0,1,0" />
                        </contentListControl:ElementFlowSettings.Camera>
                    </contentListControl:ElementFlowSettings>
                </contentListControl:ContentList.Settings>
            </contentListControl:ContentList>
            <Label x:Name="lblNoNews" Grid.Row="2" Grid.Column="0" FontFamily="Georgia" FontSize="20" FontWeight="Bold" Foreground="White" Content="Content not Available" Padding="0" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,0,20,0" Visibility="Collapsed"/>
            <Grid x:Name="grid" Margin="20,0" VerticalAlignment="Bottom" Grid.ColumnSpan="2" Grid.Row="3" RenderTransformOrigin="0.5,0.5">
                <Grid.RenderTransform>
                    <TransformGroup>
                        <ScaleTransform/>
                        <SkewTransform/>
                        <RotateTransform/>
                        <TranslateTransform/>
                    </TransformGroup>
                </Grid.RenderTransform>
                <controls:ToolbarControl Grid.Column="0" x:Name="toolbarControl" HorizontalAlignment="Stretch" Height="100" d:LayoutOverrides="GridBox" RenderTransformOrigin="0.5,0.5">
                    <controls:ToolbarControl.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform/>
                            <SkewTransform/>
                            <RotateTransform/>
                            <TranslateTransform/>
                        </TransformGroup>
                    </controls:ToolbarControl.RenderTransform>
                </controls:ToolbarControl>
                <Button x:Name="btnShowToolbarBar" Margin="0,-20,0,0" VerticalAlignment="Top" Content="" HorizontalAlignment="Center" Width="100" Height="20" d:LayoutOverrides="GridBox" Visibility="Collapsed" Cursor="Hand">
                    <Button.Template>
                        <ControlTemplate TargetType="{x:Type Button}">
                            <Image Stretch="Fill" Source="pack://application:,,/Quibbler - Universal News Reader;component/Images/ToolbarHandle.png"/>
                        </ControlTemplate>
                    </Button.Template>
                </Button>
            </Grid>
        </Grid>
        <controls:SettingsControl x:Name="settingsControl" Visibility="Collapsed"/>
        <Border x:Name="message" Background="#FFEAEAEA" Visibility="Collapsed" >
            <Grid>
                <Border x:Name="border" HorizontalAlignment="Center" VerticalAlignment="Center" CornerRadius="5" BorderThickness="1" Padding="20,5" Background="#FF262626">
                    <Border.BorderBrush>
                        <LinearGradientBrush EndPoint="0.99,0.99" StartPoint="0.01,0.01">
                            <GradientStop Color="#FF878787"/>
                            <GradientStop Color="White" Offset="0.498"/>
                            <GradientStop Color="#FF818181" Offset="1"/>
                        </LinearGradientBrush>
                    </Border.BorderBrush>
                    <Grid Margin="5">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="Auto"/>
                            <ColumnDefinition Width="*"/>
                        </Grid.ColumnDefinitions>
                        <Image x:Name="imgMsgIcon" Width="80" Height="80" Stretch="Uniform" HorizontalAlignment="Left" Visibility="Collapsed" Margin="0,0,10,0" VerticalAlignment="Center"/>
                        <StackPanel Grid.Column="1" Orientation="Vertical" MaxWidth="250">
                            <TextBlock x:Name="txtMsgText" Text="Loading..." Foreground="#FFE2E2E2" FontSize="26.667"/>
                            <TextBlock x:Name="txtMsgDescription" Foreground="DarkGray" TextWrapping="Wrap" Visibility="Collapsed"/>
                        </StackPanel>
                    </Grid>

                </Border>
                <TextBlock Foreground="#FF888888" VerticalAlignment="Bottom" HorizontalAlignment="Left" Margin="5">
					<Run Text="Version: "/>
					<TextBlock x:Name="txtVersion"/>
				</TextBlock>
            </Grid>
        </Border>
    </Grid>
</common:QuibblerWindow>
